import QtQuick 2.0
import QtQuick.Controls 2.12
import QtQuick.Layouts 1.12
import "qrc:/qmlComponents/ConfigManager"
import "qrc:/qmlComponents/AxisModulePos"

Item {
    RowLayout{
        spacing: 40

        ObjectEditor{
            Layout.alignment: Qt.AlignTop

            sectionName: qsTr("DispenseWorkHolderConfig")
            configModel: dispWHConfig
            Component.onCompleted: {
                init()
            }
        }

        ColumnLayout{
            Layout.alignment: Qt.AlignTop

            SAxisModulePos{
                moduleName: "DispWHBeltZ"
                posName: "UpPos"
            }
            SAxisModulePos{
                moduleName: "DispWHBeltZ"
                posName: "DownPos"
            }
            Button{
                text: qsTr("getNewTray")
                onClicked: {
                    tem.runSingleCmd(dispWorkHolder, "manuallyGetNewTray")
                }
            }
            Button{
                text: qsTr("returnBackTray")
                onClicked: {
                    tem.runSingleCmd(dispWorkHolder, "returnBackTray")
                }
            }
        }
    }
}

